1. Technical Field
The present invention relates to an improved data processing system. In particular, the present invention relates to a method, apparatus, and computer instructions for sharing input/output (I/O) facilities owned by a logical partition with other logical partitions.
2. Description of Related Art
Computing platforms that support partitioning, and even more importantly logical partitioning, such as the IBM iSeries and pSeries, often run small independent operating system images known as xe2x80x9chosted partitionsxe2x80x9d. xe2x80x9cHosted partitionsxe2x80x9d are logical partitions that rely on another one of the platform""s logical partitions known as xe2x80x9chosting partitionsxe2x80x9d to provide some or all of the hosted partition""s physical I/O facilities. Several hosted partitions can share the physical I/O facilities, such as for example disk adapters and devices, of the hosting partition. In principal any I/O device owned by a hosting partition may be shared with a hosted partition, these include but are not limited to tape, CD, and DVD drives, Local Area Network adapters such as token ring or ethernet, serial ports and terminals, non-volatile ram, real time clock and timer devices. This invention relates to any of these or other I/O devices that uses Direct Memory Access (DMA) facilities.
The current art of DMA transfers, as practiced by the IBM iSeries and pSeries computer platforms, includes a level of address translation called a translation control entry (TCE) table, per I/O adapter. The TCE tables within logically partitioned platforms are maintained by a platform firmware component known as the hypervisor, which insures that the data within the TCE directs the DMA accesses of I/O adapters to the proper target memory. Currently, the hypervisor requires that this target memory is owned by the partition owning the I/O adapter.
Current art provides a communications path among the various partitions through the hypervisor. This path is used to exchange I/O requests and responses by the means of the hypervisor copying data between the memory, which is owned by the hosted and hosting partitions. The primary responsibility of the hypervisor is to protect one partition""s memory from corruption by errors in other partitions. Therefore, the hypervisor must mediate any data movement between partitions to insure that the only data approved by their respective owning partitions are involved. With current art, the only two means available are to copy the data between two buffers, one in the source and one in the destination, or to map a segment of memory for shared access by both partitions. The former requires that when the hosting partition makes an I/O request of the hosted partition, in addition to the direct memory access (DMA) transfer of data to and from the I/O adapter, the hypervisor must copy, using processor loads and stores, the data between hosted and hosting partitions. These data copy operations significantly add to the overhead of doing I/O in a hosted or hosting environment, especially as the size of I/O data associated with an I/O operation increases. The other alternative of mapping a shared segment of storage involves operational problems including significant increase in memory consumption, and difficulty in reclaiming memory in the face of errors.
Therefore, it would be advantageous to have an improved method, apparatus, and computer instructions for logical partitions to share physical I/O facilities with other logical partitions.
The present invention provides a method, apparatus, and computer implemented instructions for sharing virtual I/O facilities of logical partitions with other logical partitions using shared translation control entries. The present invention creates a remote translation control entry table for a hosted partition, wherein the hosted partition is a logical partition sharing the I/O facilities owned by a hosting partition. The remote translation control entry table of the hosted partition is loaded by the hypervisor in response to request made by the hosted partition""s Operating System. The hypervisor copies selected entries from the remote translation control entry table into selected entries in a standard translation control entry table maintained for a hosting partition per requests made by the hosting partition""s Operating System, wherein the hosting partition is the logical partition owning the physical I/O facilities making them available to the hosted partition as virtual I/O facilities. These virtual I/O facilities of the hosted partition are realized by the hosting partition""s physical I/O facilities, accessing the hosted partition""s memory using the data stored in the standard translation control entry table on the hosting partition as copied by the hypervisor from the remote TCE tables of the hosted partition""s virtual I/O facilities.